//
//  DefaultTools.h
//  GGInternbird
//
//  Created by iOSer on 16/6/3.
//  Copyright © 2016年 耿文康. All rights reserved.
//

#import <Foundation/Foundation.h>
#import <UIKit/UIKit.h>
@interface DefaultTools : NSObject
+ (DefaultTools *)sharedInstance;

/**
 *  本地化存储
 */
-(NSArray *)dataReadWithFPBanner;//读取首页banner信息
-(void)dataWriteWithFPBanner:(NSArray *)fpBannerArray;//写入首页banner信息
-(BOOL)fpBannerDataStore;//banner存储时间与本地时间差 大于两个小时返回YES
-(void)dataStoreTimeWithFPBanner;//记录banner储存时间

-(void)dataWriteWithHotSearchArray:(NSArray *)HotSearchArray;//写入热门搜索信息
-(NSArray *)dataReadWithHotSearch;//读取热门搜索信息
-(void)dataStoreTimeWithHotSearch;
-(BOOL)hotSearchDataStore;

//推送消息处理
//-(NSDictionary *)pushMsgRead;//读取消息
//-(void)pushMsgClearWithName:(NSString *)name;//清理消息
//-(void)pushMsgPointAddMsg:(NSString *)msg andTime:(NSNumber *)time andName:(NSString *)name;//添加消息
//是否第一次启动
-(BOOL)isAppFirstStart;
-(void)appFirstStartWith:(BOOL)boo;
-(NSString *)timeSwitchString:(double)time andDateFomat:(NSString *)dateFormat;//输入格式自动返回时间

//正则判断
//手机号
- (BOOL)validatePhoneNumber:(NSString *) textString;
//密码
- (BOOL)validatePass:(NSString *) textString;
/**
 *  跳转相关
 *
 */
-(UIViewController *)getCurrentVC;//获取当前控制器
//tabbar小圆点显示
//-(void)TabbarItemHiddenDisplay:(UITabBarController *)vc;
//阴影Layer处理
-(CALayer *)baseLayerMake;
-(NSString *)nowDateWithTime;
//根据颜色生成图片
-(UIImage *)imageMakeWithRect:(CGRect)rect Color:(UIColor *)color;
//加班时间计算
-(void)workPlusTimeWithString:(NSString *)string;
@end


@interface GGShowHUDTool : NSObject

+ (GGShowHUDTool *)sharedInstance;

-(void)showInfoHudWith:(NSString *)str;
-(void)showYesHudWith:(NSString *)str;
-(void)showNoHudWith:(NSString *)str;
-(void)showGetHud:(NSString *)str;
-(void)showGetHud:(NSString *)str withTime:(NSTimeInterval)time;
-(void)showImage:(UIImage *)image andString:(NSString *)string;
-(void)dismiss;
@end
